from BeautifulReport import BeautifulReport
import time
import unittest

#获取用例集合
test_dir = "cases"

discover = unittest.defaultTestLoader.discover(test_dir,pattern='test_task.py')

#BeautifulReport报告运行用例，结果写入报告
BeautifulReport(discover).report(description=u'自动化测试报告',
                                 log_path='./report/',
                                 filename=time.strftime("%Y-%m-%d-%H_%M_%S")
                                 )
